package com.sx.service.impl;


import com.github.pagehelper.PageInfo;
import com.sx.dao.ResourceMapper;
import com.sx.domain.Resource;
import com.sx.domain.ResourceVo;
import com.sx.service.ResourceService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ResourceServiceImpl implements ResourceService {
    @Autowired
    private ResourceMapper resourceMapper;

    @Override
    public PageInfo<Resource> findAllResource(ResourceVo resourceVo) {
        List<Resource> allResource = resourceMapper.findAllResource(resourceVo);
        PageInfo<Resource> adPageInfo = new PageInfo<Resource>(allResource);
        return adPageInfo;
    }
}
